package ExercicioRMI;

import java.rmi.*;

public class Cliente {
	
	public static void main (String[] args){
		new Cliente().go();
	}
	
	public void go() {
		try {
			
			java.rmi.registry.LocateRegistry.getRegistry();
			InterfaceServ service = (InterfaceServ) Naming.lookup("rmi://localhost/Mensagem Hello");
			String s = service.strHello();
			
			
			System.out.println(s);
		} catch(Exception ex){
			ex.printStackTrace();
		}
	}

}
